#ifndef LUCNX_DEBUG_H
#define LUCNX_DEBUG_H

#include <Lucnx/printk.h>

void _panic(int line, char *file_name, char *conition, ...);
void _infok(char *type, char *fmt, ...);
void _outk(char *exporter, char *fmt, ...);

#define DEBUGK(str, args...) _infok("DEBUG", str, ##args)
#define INFOK(type, str, args...) _infok(type, str, ##args)
#define OUTK(str, args...) _outk(__FUNCTION__, str, ##args)
#define LOGK(str, args...) _infok("LOGK", str, ##args)

#define assert(conition)                        \
if (conition)                                   \
    ;                                           \
else                                            \
    _panic(__LINE__,__FILE__,#conition);         

#define panic(str, args...) _panic(__LINE__, __FILE__, str, ##args)

#endif